#include<bits/stdc++.h>
using namespace std;
int n;
int r[100005];
int t[100005];
int ans[100005];
int main(){
    freopen("duel.in","r",stdin);
    freopen("duel.out","w",stdout);
    cin>>n;
    for(int i=1;i<=n;i++){
        cin>>r[i];
        t[r[i]]++;
    }
    sort(r+1,r+1+n);
    ans[1]=0;
    int s=n;
    for(int i=1;i<=n;i++){
        ans[i]=ans[i-1];
        if(r[i-1]<r[i])ans[i]+=t[r[i-1]];
        if(ans[i]>0){ans[i]--;s--;}
    }
    cout<<s<<endl;
    fclose(stdin);
    fclose(stdout);
    return 0;
}